Open the repo at https://github.com/dlab-berkeley/Geospatial-Fundamentals-in-R-with-sf
- Download and unzip the zip file
- Take note of where the folder is located
Start RStudio and open a new script, or ./docs/02-spatial_analysis.Rmd
Set your working directory to the folder you unzipped
Install the required libraries in RStudio, if you do not have them already
install.packages(
c("ggplot2", "ggmap", "sf", "units", "tmap", "nngeo", "raster"),
dependencies=TRUE)
- Open the slides, ./docs/02-spatial-analysis.html, in your browser (or click the “Part 2 Slides” link the repo).